<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
	<title>Document</title>
   <style type="text/css">
	       .box{
	           width: 200px;
	           height: 200px;
	           background: #99B800;      
	}
	</style>

	<script type="text/javascript">
/*
      var y=5;
      var x=5;
      var z=x+y;
      alert(z);




  先声明后赋值
     var name;
      name ="ddddd";
      alert(name);*/


 /* 循环for
for (var i=10; i>0; i--){
     	document.write(i)
 }



循环while
n=0;
while(n<10)
{
    n++;
    document.write(n)
}



循环do.while
n=10;
do{
    n++;
    document.write(n)
}while(n<10)




与或非
var a=true;
var b=true;
alert(a&&b);
var a=true;
var b=false;
alert(a||b);
var a=true;
alert(!a);*/

/*
判断

var n=10
if(n>15){
   alert("ddadad")
}
if(n<15){
	alert(5555)
}
else{
   alert("cuocuoc")
}*/

/*语句switch*/
/*var n = 5;
switch(n){
    case 5:
        alert('执行case分支');
        break;
    default:
        alert('执行default分支');
}
*/
/*function myFunction(){
		alert("Hello World!");
	}*/

	/*var myFunction = function  () {
		alert("Hello World!");
	}
	myFunction();*/



	/*function myFunction(){
		alert("Hello World!");
	}*/

/*function car () {
		this.name="奥迪";
		this.color="红色";
		this.run = function  () {
			alert("可以跑");
		}
		this.ziaren = function  () {
			alert("可以载人");
		}
	}*/
	/*var x
	var city = new Array()
	city[0] = "北京"
	city[1] = "广州"
	city[2] = "东莞"

	for (x in city){
		document.write(city[x] + "<br />")
	}
*/
 
  </script>
	<!-- <div class="box" onclick="myFunction()"></div> -->
	 





</head>
<body>
	
	
</body>
</html>